import 'package:flutter/widgets.dart';

class InputState {
  ///用户文字输入内容
  late String inputContent;

  ///会话id
  String? id;

  ///语音输入文字提示
  late String audioHint;
  late bool isAudio; //是否为语音输入
  late bool isEmoji; //是否为emoji输入
  late bool showMore; //是否展示更多选项
  late bool showKeyBoard; //软键盘是否弹出,如果弹出,底部增加一个view,将输入框顶起来

  String? chatId;
  bool? isGroup;
  late TextEditingController editingController;

  ///语音指示器
  late String voiceIndicator; //语音输入声音大小指示器
  late bool showAudioOverlay; //是否展示语音指示器
  late bool cancelAudio; //是否取消语音发送
  late String audioNotify;

  ///手指按下的位置,计算上滑距离以判断是否需要取消发送
  late double startPosition;

  InputState(){
    inputContent="";
    cancelAudio = false;
    startPosition = 0;
    audioNotify = "手指上滑,取消发送";
    showAudioOverlay = false;
    voiceIndicator = "voice_volume_1.png";
    showKeyBoard = false;
    showMore = false;
    isEmoji = false;
    isAudio = false;
    audioHint = '按住说话';
    editingController = TextEditingController();
  }
}
